home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga Plus 1995 #5 & #6
/
Amiga Plus CD - 1995 - No. 5 and 6.iso
/
pd
/
serien
/
purity
/
nr.10
/
demo
/
sparx.i
/
.spark17.i
< prev
next >
Wrap
Text File
|
1995-04-19
|
1KB
|
98 lines
Procedure Spark17;
Const
max4lines = 50;
Type
Sp1lines = Array[1..max4lines] of line;
Sp1LinesPtr = ^Sp1Lines;
Var
arr : Sp1LinesPtr;
a1x,a1y,
a2x,a2y,
CCNT,
actualline : Short;
Procedure Inner17;
Begin
With arr^[actualline] do begin
x1 := a1x; y1 := a1y;
x2 := a2x; y2 := a2y;
end;
DrawLine( Adr(arr^[actualline]), CCNT );
inc( CCNT );
If CCNT >= maxColors then CCNT := 2;
inc( actualline );
If actualline >= max4lines then actualline := 1;
End;
Begin
New(arr);
ActualLine := 1;
{ ** old .sp15 : ** }
CCNT := 2; { color }
a1x := 60; a1y := 28;
a2x := 260; a2y := 230;
Repeat
EraseLine( Adr(arr^[actualline]) );
If a1y=28 then inc(a1x);
If a1y=230 then dec(a1x);
If a1x=260 then inc(a1y);
If a1x=60 then dec(a1y);
If a2y=28 then inc(a2x);
If a2y=230 then dec(a2x);
If a2x=260 then inc(a2y);
If a2x=60 then dec(a2y);
Inner17;
Until LeftMouseButton;
Ciao;
{ ** old .sp17 : ** }
CCNT := 2; { color }
a1x := 61; a1y := 28;
a2x := 260; a2y := 29;
SetSColors( Adr(GreenMap) );
Repeat
EraseLine( Adr(arr^[actualline]) );
If a1y=28 then inc(a1x);
If a1y=230 then dec(a1x);
If a1x=260 then inc(a1y);
If a1x=60 then dec(a1y);
If a2y=28 then inc(a2x);
If a2y=230 then dec(a2x);
If a2x=260 then inc(a2y);
If a2x=60 then dec(a2y);
Inner17;
Until LeftMouseButton;
Ciao;
Dispose(arr);
SetSColors(Adr(Def_Colors));
End;